#include "PortItem.h"


PortItem::PortItem(AbsIoNode* node, QGraphicsItem* parent) : QGraphicsTextItem(parent), m_node(node)
{
    setPlainText(node->name());
}

PortItem::~PortItem() { }

int PortItem::id()
{
    return m_node->id();
}

void PortItem::setNode(AbsIoNode* node)
{
    m_node = node;
}

AbsIoNode* PortItem::node()
{
    return m_node;
}
